home *** CD-ROM | disk | FTP | other *** search
- Path: news.umbc.edu!not-for-mail
- From: schlein@umbc.edu (Jonas J. Schlein)
- Newsgroups: comp.lang.c
- Subject: Re: Help with simple code
- Date: 16 Jan 1996 21:00:08 -0500
- Organization: University of Maryland Baltimore County
- Message-ID: <4dhl78$fd1@umbc9.umbc.edu>
- References: <4dbak5$oij@ionews.io.org> <4deocm$4co@su3.in.net>
- NNTP-Posting-Host: f-umbc9.umbc.edu
- NNTP-Posting-User: schlein
-
- |> Can anyone tell me what's wrong with this piece of code? I lifted it
- |> straight from a textbook.
- |>
- |> Here's the code:
-
- <code unnecessary for analysis of problem>
-
- |> and here's the error:
- |>
- |> In function `main':
- |> undefined reference to `pow'
- |>
- |> I don't understand. `pow' is a function, not a variable?
- |> Can anyone tell me what's wrong?
-
- I suspect you may be using UNIX, but in any case you did include <math.h>,
- not shown, so the problem is most likely a link problem and not with
- the compiler or your code. This is addressed in FAQ questions 13.25,
- 13.26 and 14.3. This is freely available in electronic format at
- ftp://rtfm.mit.edu/pub/usenet-by-hierarchy/comp/lang/c/C-FAQ-list.
- --
- "If it wasn't for C, we would be using BASI, PASAL, and OBOL."
-
- Jonas J. Schlein (schlein@gl.umbc.edu)
-